﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="newsmanager.aspx.cs" Inherits="Sys_newsmanager" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>新闻编辑</title>
     <link rel="stylesheet" type="text/css" href="../js/themes/default/easyui.css"/>
	<link rel="stylesheet" type="text/css" href="../CSS/Style.css"/>
    <script type="text/javascript" src="../js/jquery-1.4.2.min.js"></script>
	<script type="text/javascript" src="../js/jquery.easyui.min.js"></script>  
</head>
<body>
    <form id="form1" runat="server">
        <div style="background: #efefef; width: 100%">
            <a class="easyui-linkbutton" href="newswriting.aspx" plain="true" target="mainwin">
                撰写公告</a> | <a class="easyui-linkbutton" href="newsmanager.aspx" plain="true" target="mainwin">
                    编辑公告</a>
        </div>
<div>
     <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
            <ContentTemplate>
        <table border="0" cellpadding="0" cellspacing="0" style="width: 100%;">
            <tr>
                <td align="center">
                <div style="background-color:#fedcbd; padding-bottom:5px;">
                    <table>
                        <tr>
                            <td>
                                公告类型：</td>
                            <td>
                                <asp:DropDownList ID="ddlType" runat="server" Width="150px">
                                    <asp:ListItem></asp:ListItem>
                                    <asp:ListItem>申报</asp:ListItem>
                                    <asp:ListItem>评审</asp:ListItem>
                                    <asp:ListItem>其他</asp:ListItem>
                                </asp:DropDownList></td>   
                             <td>
                                 标题关键字：</td>
                            <td>
                                <asp:TextBox ID="txtTitlekeywords" runat="server" Width="145px"></asp:TextBox></td>   
                            <td>
                                内容关键字：</td>
                            <td>
                                <asp:TextBox ID="txtContentkeywords" runat="server" Width="145px"></asp:TextBox></td>    
                            <td>
                                <asp:ImageButton ID="btnSerch" runat="server" ImageUrl="~/Images/search.png" OnClick="btnSerch_Click" /></td>
                        </tr>
                    </table>
                   </div> 
                </td>
            </tr>
            <tr>
                <td >
                    <webdiyer:AspNetPager ID="AspNetPager1" runat="server" AlwaysShow="True" CustomInfoHTML="共<font color=blue><b>%RecordCount%</b></font>条数据 每页：<font color=blue><b>%PageSize%</b></font> 条 共<font color=blue><b>%PageCount%</b></font>页 当前页：<font color=red><b>%CurrentPageIndex%/%PageCount%</b></font>"
                        CustomInfoSectionWidth="50%" FirstPageText="首页" HorizontalAlign="Right" LastPageText="末页"
                        NextPageText="下一页" OnPageChanged="AspNetPager1_PageChanged" PageIndexBoxType="TextBox"
                        PageSize="15" PrevPageText="上一页" ShowCustomInfoSection="Left" ShowPageIndexBox="Always"
                        SubmitButtonText="Go" TextAfterPageIndexBox="页" TextBeforePageIndexBox="转到" Width="100%" CustomInfoTextAlign="Left">
                    </webdiyer:AspNetPager>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CssClass="gvStyle" AlternatingRowStyle-CssClass="alt" PagerStyle-CssClass="pgr" EmptyDataText="暂时无任何数据！" Width="100%" OnRowCommand="GridView1_RowCommand">
                        <Columns>
                            <asp:BoundField DataField="id" HeaderText="编号" />
                            <asp:BoundField DataField="type" HeaderText="类型" />
                            <asp:TemplateField HeaderText="公告标题">
                                <ItemTemplate>
                                    <a href='../News/Newsdetail.aspx?id=<%# Eval("id") %>' target="_parent">
                                        <%#strTrim(Convert.ToString(Eval("title")))%>
                                    </a>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="date" HeaderText="发表时间" />
                            <asp:BoundField DataField="ishighlight" HeaderText="标题高亮" />
                            <asp:TemplateField HeaderText="编辑操作">
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnHighlight" runat="server" ImageUrl="~/js/themes/icons/highlight.png" CommandArgument='<%# Eval("id") %>' CommandName="Highlight" OnClientClick="return confirm('确定更改此公告标题的高亮状态?');"/>&nbsp;
                                    <asp:ImageButton ID="btnEdit" runat="server" ImageUrl="~/js/themes/icons/pencil.png" CommandArgument='<%# Eval("id") %>' CommandName="NewsEdit" OnClientClick="return confirm('确定重新编辑此公告?');"/>&nbsp;
                                    <asp:ImageButton ID="btnDelete" runat="server" ImageUrl="~/js/themes/icons/cancel.png" CommandArgument='<%# Eval("id") %>' CommandName="NewsDelete" OnClientClick="return confirm('公告删除后将无法恢复，务必谨慎操作！！是否确定要删除此公告?');"/>
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                        <PagerStyle CssClass="pgr" />
                        <AlternatingRowStyle CssClass="alt" />
                    </asp:GridView>
                </td>
            </tr>
        </table>
         </ContentTemplate>
        </asp:UpdatePanel>
    </div>
    </form>
</body>
</html>
